/*
 * Frame.h
 * Frame Class
 *
 * author : T. D. Gamage
 */

#pragma once
#include <string>
#include <cv.h>
#include <highgui.h>
#include <cxcore.h>
#include <cvaux.h>
#include <time.h>

#define COLOR_HIST_DIMENTION_LENGTH 16
#define COLOR_HIST_MIN_VALUE 0
#define COLOR_HIST_MAX_VALUE 256

using namespace std;
class Frame
{
private:
    int frameNo;
    string fileName;
	IplImage* image;
	 IplImage* grayImage;
	CvHistogram* histogram;
	CvMat* signature;
	time_t time;
public:
    
    Frame(void);
	void setFrameNo(int frameNo);
	int getFrameNo();
    void setFileName(string fileName);
    string getFileName();
	void setFrame(IplImage *image);
    IplImage* getFrame();
    IplImage* getGrayFrame();
    double getThreshVal_Otsu( const CvHistogram* hist );
    int getOptimumThreshold();
    
   void setTime(time_t time);
    time_t getTime();
    
    CvSize getFrameSize();
    IplImage* getLicensePlate();
    
    CvHistogram* getHistogram();
    CvMat* getSignature();
    void showFrame(IplImage* image);

    virtual ~Frame(void);
};
